<template>
  <div class="III-I-I">
    <div class="III-I-I__title">
      III科学研究水平
    </div>
    <table class="III-I-I__tableone">
      <tr class="III-I-I__tableone-trone">
        <td class="III-I-I__tableone-trone-td"
            colspan="3">
          <div class="III-I-I__tableone-trone-td-title">
            III-1 学术论文质量
          </div>
          <div class="III-I-I__tableone-trone-td-desc">
            从本学科发表的学术论文中凝练出5项标志性学术成果；每项成果分别简述其原创性、前沿性、突破性创新内容和学术贡献，并提供至少1篇代表性学术论文进行支撑（须包含至少1篇中国期刊论文）。代表性论文总数不超过40篇，同一教师作为第一作者的论文不超过3篇。
          </div>
        </td>
      </tr>
      <tr class="III-I-I__tableone-trtwo">
        <td class="III-I-I__tableone-trtwo-tdone">
          成果简称
          <span class="III-I-I__tableone-trtwo-tdone-tips">
            （限20字）
          </span>
        </td>
        <td class="III-I-I__tableone-trtwo-tdtwo">
          原创性、前沿性、突破性创新内容和学术贡献
          <span class="III-I-I__tableone-trtwo-tdtwo-tips">
            （限150字）
          </span>
        </td>
        <td class="III-I-I__tableone-trtwo-tdthree">
          自我评价
        </td>
      </tr>
      <tr class="III-I-I__tableone-trthree">
        <td class="III-I-I__tableone-trthree-tdone">
          <el-input
            v-model="caa.resultIntro"
            class="III-I-I__tableone-trthree-tdone-input"
            type="textarea"
            autosize
            placeholder="请填写成果简称"
            :maxlength="20"/>
        </td>
        <td class="III-I-I__tableone-trthree-tdtwo">
          <el-input
            v-model="caa.contribution"
            class="two_indent"
            type="textarea"
            autosize
            placeholder="请填写原创性、前沿性、突破性创新内容和学术贡献"
            :maxlength="150"/>
        </td>
        <td class="III-I-I__tableone-trthree-tdthree">
          <el-checkbox-group v-model="caa.selfEvaluation">
            <el-checkbox label="国际领先"/>
            <el-checkbox label="国际先进"/>
            <el-checkbox label="国内领先"/>
            <el-checkbox label="国内先进"/>
            <el-checkbox label="其他"/>
          </el-checkbox-group>
        </td>
      </tr>
    </table>
    <table class="III-I-I__tabletwo">
      <tr class="III-I-I__tabletwo-th">
        <td class="III-I-I__tabletwo-th-tdone">
          序号
        </td>
        <td class="III-I-I__tabletwo-th-tdtwo">
          论文题目
        </td>
        <td class="III-I-I__tabletwo-th-tdthree">
          DOI号
        </td>
        <td class="III-I-I__tabletwo-th-tdfour">
          第一<br>作者
        </td>
        <td class="III-I-I__tabletwo-th-tdfive">
          通讯<br>作者
        </td>
        <td class="III-I-I__tabletwo-th-tdsix">
          刊物/会议名称
        </td>
        <td class="III-I-I__tabletwo-th-tdseven">
          发表<br>时间
        </td>
        <td class="III-I-I__tabletwo-th-tdeight">
          署名情况
        </td>
        <td class="III-I-I__tabletwo-th-tdnine">
          境外<br>合作
        </td>
        <td class="III-I-I__tabletwo-th-tdten">
          体现论文水平的有关说明<br>
          <span class="III-I-I__tabletwo-th-tdten-tips">
            （限30字）
          </span>
        </td>
        <el-button type="success"
                   size="small"
                   icon="el-icon-plus"
                   class="III-I-I__tabletwo-th-add-button"
                   circle
                   @click.prevent="addMaterList()"/>
      </tr>
      <tr v-for="(item, index) in caa.paperInfos"
          :key="index"
          class="III-I-I__tabletwo-tr">
        <td class="III-I-I__tabletwo-tr-tdone">
          {{ index + 1 }}
        </td>
        <td class="III-I-I__tabletwo-tr-tdtwo">
          <el-input
            v-model="item.title"
            class="III-I-I__tabletwo-tr-tdtwo-input"
            type="textarea"
            placeholder="XXXX"
            autosize/>
        </td>
        <td class="III-I-I__tabletwo-tr-tdthree">
          <el-input
            v-model="item.doi"
            class="III-I-I__tabletwo-tr-tdthree-input"
            type="textarea"
            placeholder="XXXX"
            autosize
            :maxlength="50"/>
        </td>
        <td class="III-I-I__tabletwo-tr-tdfour">
          <el-input
            v-model="item.firstAuthor"
            class="III-I-I__tabletwo-tr-tdfour-input"
            type="textarea"
            placeholder="张三"
            autosize/>
        </td>
        <td class="III-I-I__tabletwo-tr-tdfive">
          <el-input
            v-model="item.corresAuther"
            class="III-I-I__tabletwo-tr-tdfive-input"
            type="textarea"
            placeholder="李四"
            autosize/>
        </td>
        <td class="III-I-I__tabletwo-tr-tdsix">
          <el-input
            v-model="item.publicName"
            class="III-I-I__tabletwo-tr-tdsix-input"
            type="textarea"
            placeholder="XXXX（CNXX-XXXX/XX）"
            autosize
            :maxlength="50"/>
        </td>
        <td class="III-I-I__tabletwo-tr-tdseven">
          <el-input
            v-model="item.publicTime"
            class="III-I-I__tabletwo-tr-tdseven-input"
            type="textarea"
            placeholder="201712"
            autosize
            :maxlength="6"/>
        </td>
        <td class="III-I-I__tabletwo-tr-tdeight">
          <el-select v-model="item.sigature"
                     class="III-I-I__tabletwo-tr-tdeight-select"
                     placeholder="请选择">
            <el-option v-for="item in options"
                       :key="item.value"
                       :label="item.label"
                       :value="item.value"/>
          </el-select>
        </td>
        <td class="III-I-I__tabletwo-tr-tdnine">
          <el-input
            v-model="item.overseasCoope"
            class="III-I-I__tabletwo-tr-tdnine-input"
            type="input"
            placeholder="是/否"
            autosize
            :maxlength="1"/>
        </td>
        <td class="III-I-I__tabletwo-tr-tdten">
          <el-input
            v-model="item.explain"
            type="textarea"
            autosize
            placeholder="请填写体现论文水平的有关说明"
            :maxlength="30"/>
        </td>
        <el-button type="danger"
                   size="small"
                   icon="el-icon-delete"
                   class="III-I-I__tabletwo-tr-delete-button"
                   circle
                   @click.prevent="deleteMaterItem(index)"/>
      </tr>
    </table>
    <div class="III-I-I__explain">
      <span class="III-I-I__explain-strong">
        说明：①
      </span>
      “成果简称”填写具体成果名称，不填写“研究方向”。
      <span class="III-I-I__explain-strong">
        ②
      </span>
      代表性论文仅限“第一作者单位”和“通讯作者单位”填写；文中若明确标注“共同第一作者”或“共同通讯作者”，以及作者根据惯例按字母顺序排列或文中标注“所有作者同等贡献”的，相关作者单位也可填写。
      <span class="III-I-I__explain-strong">
        ③
      </span>
      同一作者标注多个单位的，仅限第一单位填写。
      <span class="III-I-I__explain-strong">
        ④
      </span>
      “署名情况”限填“第一作者及通讯作者、第一作者、通讯作者、共同通讯作者、同等贡献作者”。
      <span class="III-I-I__explain-strong">
        ⑤
      </span>
      在中国期刊（包括中国机构出版的外文期刊，一般应具有CN号）上发表的论文，请在“刊物/会议名称”后注明CN号。
      <span class="III-I-I__explain-strong">
        ⑥
      </span>
      除外籍教师外，论文作者均填写中文姓名（含外文发表的论文）。
      <span class="III-I-I__explain-strong">
        ⑦
      </span>
      所提供代表性论文的核心内容，应能有效支撑标志性成果，专家评价时不以“论文引用”等计量指标为主要依据。
      <span class="III-I-I__explain-strong">
        ⑧
      </span>
      请如实对成果进行自我评价。
    </div>
  </div>
</template>

<script>
import { getPageData } from '@/utils/getData.js'

export default {
  watch: {
    caa: {
      handler (newVal) {
        sessionStorage['this_data'] = JSON.stringify(newVal)
      },
      deep: true,
      immediate: true
    }
  },
  async mounted () {
    const loading = this.$loading({ lock: true, text: '数据获取中...请稍后！', background: 'rgba(0, 0, 0, 0.7)' })
    this.caa = await getPageData('caa')
    loading.close()
  },
  data () {
    return {
      options: [
        { value: '0', label: '第一作者及通讯作者' },
        { value: '1', label: '第一作者' },
        { value: '2', label: '通讯作者' },
        { value: '3', label: '共同通讯作者' },
        { value: '4', label: '同等贡献作者' }],
      caa: {
        resultIntro: '',
        contribution: '',
        selfEvaluation: [],
        paperInfos: [
          { title: '', doi: '', firstAuthor: '', corresAuther: '', publicName: '', publicTime: '', sigature: '', overseasCoope: '', explain: '' }
        ]
      }
    }
  },
  methods: {
    addMaterList () {
      if (this.caa.paperInfos.length < 40) {
        this.caa.paperInfos.push({ title: '', doi: '', firstAuthor: '', corresAuther: '', publicName: '', publicTime: '', sigature: '', overseasCoope: '', explain: '' })
      }
    },
    deleteMaterItem (index) {
      if (this.caa.paperInfos.length > 1) {
        this.caa.paperInfos.splice(index, 1)
      }
    }
  }
}
</script>

<style lang="less" scoped>
@import '../../assets/css/page/3-1-1.less';
</style>
